/*
 *  Copyright 2020-2025 the original author or authors.
 *  You cannot use this file unless authorized by the author.
 */

package org.ipig.computing.commons.pojo.kafka;

import lombok.Data;
import lombok.ToString;

import java.io.Serializable;

/**
 * Kafka记录信息
 *
 * @author <a href="mailto:comchnts@163.com">chinats</a>
 * @since 1.0
 */
@Data
@ToString
public class KafkaRecordInfo<K, V> implements Serializable {
    public transient static final String TOPIC = "topic";//主题
    public transient static final String PARTITION = "partition";//分区
    public transient static final String OFFSET = "offset";//偏移量

    private String topic = "";
    private int partition;
    private long offset;
    private long timestamp;
    //    private  TimestampType timestampType;
    private long checksum;
    private int serializedKeySize;
    private int serializedValueSize;
    private K key;
    private V value;
    //原始记录
    private K origRecord;
/*    private final TimestampType timestampType;
    private final Headers headers;
    private final Optional<Integer> leaderEpoch;*/
}
